package com.yunhe.openapi.util;

import com.yunhe.common.model.ResultObject;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;

/**
 * 断路器工具
 * @author liuronglei
 */
public class FallbackUtil {

    /**
     * 返回默认断路器
     */
    public static <T> T getDefaultFallBack() {
        return (T)new ResponseEntity<>(new ResultObject<>(null), HttpStatus.BAD_GATEWAY);
    }
}
